﻿Imports System.Data
Imports System.Data.Odbc
Imports WSEntidades
Public Class PeriodosiFact
    Public Shared Function Build(ByVal dr As OdbcDataReader) As PeriodosiBE
        Dim tmpPeriodosi As PeriodosiBE = New PeriodosiBE()
        Try
            With tmpPeriodosi
                .FechaF = convertDTFromDb.convertDateTime(dr.Item("FechaF"))
                .FechaI = convertDTFromDb.convertDateTime(dr.Item("FechaI"))
                .IdEmpresa = convertDTFromDb.ConvertShort(dr.Item("IdEmpresa"))
                .Periodo = convertDTFromDb.convertInt32(dr.Item("Periodo"))
                .Status = convertDTFromDb.ConvertShort(dr.Item("Status"))
                .UsrCierre = convertDTFromDb.convertInt32(dr.Item("UsrCierre"))
                .UsrCrea = convertDTFromDb.convertInt32(dr.Item("UsrCrea"))
            End With
            Return tmpPeriodosi
        Catch ex As Exception
            Throw
        Finally
            tmpPeriodosi = Nothing
        End Try
    End Function
End Class
